Skip to content

ci: wire RAG001 logging check into ci.yml on all OSes - #38

Merged
officialCodeWork merged 3 commits into
mainfrom
fix/ci-rag001-gate
May 23, 2026
Merged

ci: wire RAG001 logging check into ci.yml on all OSes#38
officialCodeWork merged 3 commits into
mainfrom
fix/ci-rag001-gate

Conversation

@officialCodeWork

Copy link
Copy Markdown
Owner

Summary

  • CLAUDE.md lists RAG001 (scripts/check_logging.py) among the blocking CI gates, but .github/workflows/ci.yml never invoked it. Until now it only ran via the pre-commit hook and the local task lint:logging target — both opt-in. That is why the packages/core/src/rag_core/audit.py violation fixed in fix(logging): allowlist rag_core/audit.py for RAG001 #37 slipped to main unnoticed.
  • This PR adds uv run python scripts/check_logging.py as a step in the existing lint-test matrix job, so the check runs on ubuntu-22.04, macos-14, and windows-latest alongside Ruff and Mypy and is gated by the same changes.outputs.python path filter.
  • No other workflow steps are touched.

Dependency

Depends on #37 (RAG001 allowlist fix for rag_core/audit.py). This branch is based on fix/rag001-audit-allowlist so CI passes here. If #37 lands first, this PR fast-forwards onto main; if this PR is reviewed first, it must wait for #37.

Documentation

  • docs/guides/logging-policy.md — appended a sentence confirming RAG001 is now enforced by the lint-test job on all three CI OSes (was previously documented as pre-commit + Taskfile only).

Test plan

  • uv run python scripts/check_logging.py exits 0 locally on this branch (after fix(logging): allowlist rag_core/audit.py for RAG001 #37's allowlist fix)
  • CI lint-test (ubuntu-22.04) step "RAG001 — logging policy check" passes
  • CI lint-test (macos-14) step "RAG001 — logging policy check" passes
  • CI lint-test (windows-latest) step "RAG001 — logging policy check" passes
  • No regression in ruff, mypy, or pytest steps

🤖 Generated with Claude Code

Deep Kumar Singh Kushwah and others added 3 commits May 24, 2026 01:08
audit.py uses stdlib `logging.getLogger("rag.audit")` because rag_observability
depends on rag_core.types, so any import from rag_core.audit into
rag_observability.logging (directly or via the rag_core.logging shim) would
create a circular import. This matches the policy described in CLAUDE.md.

Also document the policy in docs/guides/logging-policy.md, including the full
allowlist table and instructions for extending it.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
CLAUDE.md lists RAG001 (scripts/check_logging.py) as a blocking CI gate,
but until now it only ran via pre-commit and `task lint:logging` — CI on
GitHub never invoked it, which is how the audit.py violation fixed in
PR #37 slipped to main.

Add `uv run python scripts/check_logging.py` as a step in the existing
`lint-test` matrix job so it runs on ubuntu-22.04, macos-14, and
windows-latest alongside ruff and mypy.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@officialCodeWork
officialCodeWork merged commit bd3b373 into main May 23, 2026
8 checks passed
officialCodeWork added a commit that referenced this pull request May 23, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant